package com.example.medicine.Mapper.yian;


import com.example.medicine.Bean.yian.yian_zhengzhuang;
import org.apache.ibatis.annotations.*;

import java.util.List;

@Mapper
public interface yian_zhengzhuangMapper {
    @Select("select * from [yian_zhengzhuang]")
    public List<yian_zhengzhuang> getAll();
    @Select("select * from [yian_zhengzhuang] where yianid=#{yianid}")
    public List<yian_zhengzhuang> getByYianId(long id);

    @Insert("insert into [yian_zhengzhuang](yianid,zhenghou) values(#{yianid},#{zhenghou})")
    @Options(useGeneratedKeys = true,keyProperty = "id",keyColumn = "id")
    public void insertOne(yian_zhengzhuang yian_zhengzhuang);

    @Delete("delete from [yian_zhengzhuang] where yianid=#{yianid}")
    public void deleteByYianId(long yianid);
}
